package com.zc.im.common.config;

import com.zc.im.common.util.SnowFlakeUtil;
import org.springframework.beans.factory.annotation.Autowired;

import javax.annotation.PostConstruct;

/**
 * Project：im
 * Date：2022/4/20
 * Time：14:48
 * Description：相关工具类配置
 *
 * @author Challen.Zhang
 * @version 1.0
 */
public class UtilConfig {

    @Autowired
    private ImConfigProperties properties;

    @PostConstruct
    public void init() {
        SnowFlakeUtil.init(properties.getWorkerId(), properties.getDataCenterId());
    }

}
